package gui;

import javax.swing.JLabel;

public class NoticeThread extends Thread {

	private String noticeText;
	private JLabel noticeLabel;

	public NoticeThread(String text, JLabel noticeLabel) {
		this.noticeLabel = noticeLabel;
		this.noticeText = text;
	}

	public void run() {
		this.noticeLabel.setText(this.noticeText);
		try {
			Thread.sleep(5000);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		this.noticeLabel.setText("");
	}
}
